package com.flexycore.iphone.model;


import com.flexycore.iphone.uikit.UINavigationController;

/**
 * 
 * @author matthieu nicolazo
 * 
 */
public class DeleteEmails implements Runnable {
	/**
	 * Field
	 */
	private UINavigationController nav;
	
	/**
	 * Constructor
	 * @param n			NavigationController displaying current View.
	 */
	public DeleteEmails(UINavigationController n){
		super();
		nav = n;
	}
	
	/**
	 * 
	 */
	public void run() {
		try {
			Thread.sleep(3000);
		} catch (InterruptedException e) { e.printStackTrace(); }
		
		// Return to root view leading to remove the pop-up.
		nav.setNavigationBarHiddenAnimated(false, false);
		nav.popToRootViewControllerAnimated(true);
	}
	
}
